﻿<phone:PhoneApplicationPage 
    x:Class="BathroomLocator.Phone.Pages.MainPage"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:phone="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone"
    xmlns:shell="clr-namespace:Microsoft.Phone.Shell;assembly=Microsoft.Phone"
    xmlns:controls="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone.Controls"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
	xmlns:pivotContent="clr-namespace:BathroomLocator.Phone.PivotContent"
    mc:Ignorable="d" d:DesignWidth="480" d:DesignHeight="696"
    FontFamily="{StaticResource PhoneFontFamilyNormal}"
    FontSize="{StaticResource PhoneFontSizeNormal}"
    Foreground="{StaticResource PhoneForegroundBrush}"
    SupportedOrientations="Portrait"  Orientation="Portrait"
    shell:SystemTray.IsVisible="True">

	<!--LayoutRoot is the root grid where all page content is placed-->
	<Grid x:Name="LayoutRoot" Background="Transparent">
		<!--Pivot Control-->
		<controls:Pivot x:Name="MainPivot" 
						Title="{StaticResource ApplicationNameString}"
						SelectionChanged="OnMainPivotSelectionChanged">
			<controls:Pivot.Items>
                
				<!-- All Bathrooms -->
				<controls:PivotItem Header="bathrooms" x:Name="Bathrooms">
					<controls:PivotItem.Content>
						<pivotContent:BathroomListPage x:Name="BathroomListPage"/>
					</controls:PivotItem.Content>
				</controls:PivotItem>
				
			</controls:Pivot.Items>
		</controls:Pivot>
	</Grid>

	<phone:PhoneApplicationPage.ApplicationBar>
		<shell:ApplicationBar IsVisible="True" IsMenuEnabled="True">
			<shell:ApplicationBarIconButton IconUri="/Toolkit.Content/appbar.logout.rest.png" Text="logout" Click="OnLogout" />

			<shell:ApplicationBar.MenuItems>
				<shell:ApplicationBarMenuItem Text="logout" Click="OnLogout" />
			</shell:ApplicationBar.MenuItems>
		</shell:ApplicationBar>
	</phone:PhoneApplicationPage.ApplicationBar>
	
</phone:PhoneApplicationPage>